import QtQuick 2.0

Rectangle {
    width: 120
    height: 60
    color: "transparent"

    Rectangle {
        id: rect1
        width: 6
        height: parent.height/2
        color: "#cccccc"
        anchors.verticalCenter: parent.verticalCenter
        anchors.left: parent.left
        anchors.leftMargin: parent.width/4
    }

    Rectangle {
        id: rect2
        width: 6
        height: parent.height/2
        anchors.verticalCenter: parent.verticalCenter
        anchors.left: rect1.right
        anchors.leftMargin: 6
        color: "#cccccc"
    }

    Rectangle {
        id: rect3
        width: 6
        height: parent.height/2
        anchors.verticalCenter: parent.verticalCenter
        anchors.left: rect2.right
        anchors.leftMargin: 6
        color: "#cccccc"
    }

    Rectangle {
        id: rect4
        width: 6
        height: parent.height/2
        anchors.verticalCenter: parent.verticalCenter
        anchors.left: rect3.right
        anchors.leftMargin: 6
        color: "#cccccc"
    }

    Rectangle {
        id: rect5
        width: 6
        height: parent.height/2
        anchors.verticalCenter: parent.verticalCenter
        anchors.left: rect4.right
        anchors.leftMargin: 6
        color: "#cccccc"
    }

    ParallelAnimation {
        id: parallelAnimation
        running: true
        loops: Animation.Infinite
        SequentialAnimation {
            PropertyAnimation {
                properties: "height"
                target: rect1
                easing.type: Easing.InOutQuad
                from: 30
                to: 60
                duration: 200
            }
            PropertyAnimation {
                properties: "height"
                target: rect1
                easing.type: Easing.InOutQuad
                from: 60
                to: 30
                duration: 200
            }
            PauseAnimation {
                duration: 800
            }
        }
        SequentialAnimation {
            PauseAnimation {
                duration: 100
            }
            PropertyAnimation {
                properties: "height"
                target: rect2
                easing.type: Easing.InOutQuad
                from: 30
                to: 60
                duration: 200
            }
            PropertyAnimation {
                properties: "height"
                target: rect2
                easing.type: Easing.InOutQuad
                from: 60
                to: 30
                duration: 200
            }
            PauseAnimation {
                duration: 700
            }
        }
        SequentialAnimation {
            PauseAnimation {
                duration: 200
            }
            PropertyAnimation {
                properties: "height"
                target: rect3
                easing.type: Easing.InOutQuad
                from: 30
                to: 60
                duration: 200
            }
            PropertyAnimation {
                properties: "height"
                target: rect3
                easing.type: Easing.InOutQuad
                from: 60
                to: 30
                duration: 200
            }
            PauseAnimation {
                duration: 600
            }
        }
        SequentialAnimation {
            PauseAnimation {
                duration: 300
            }
            PropertyAnimation {
                properties: "height"
                target: rect4
                easing.type: Easing.InOutQuad
                from: 30
                to: 60
                duration: 200
            }
            PropertyAnimation {
                properties: "height"
                target: rect4
                easing.type: Easing.InOutQuad
                from: 60
                to: 30
                duration: 200
            }
            PauseAnimation {
                duration: 500
            }
        }
        SequentialAnimation {
            PauseAnimation {
                duration: 400
            }
            PropertyAnimation {
                properties: "height"
                target: rect5
                easing.period: 2
                easing.type: Easing.InOutQuad
                from: 30
                to: 60
                duration: 200
            }
            PropertyAnimation {
                properties: "height"
                target: rect5
                easing.period: 2
                easing.type: Easing.InOutQuad
                from: 60
                to: 30
                duration: 200
            }
            PauseAnimation {
                duration: 400
            }
        }
    }
}
